/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package br.com.eurotrader.converters;

import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;
import javax.faces.convert.Converter;

/**
 *
 * @author Usuário
 */
public class MaiusculoConverter implements Converter {

    public Object getAsObject(FacesContext arg0, UIComponent arg1, String str) {    
        if(str != null){
          //  System.out.println("passei aqui");
            String str1 = str.toUpperCase();            
            return str1;
        }
        return null;
    }

    public String getAsString(FacesContext arg0, UIComponent arg1, Object valor) {      
        if(valor!= null){
        //    System.out.println("aqui");
            return valor.toString();
        }
        return  null;
    }

}
